package cc.zy.base.hr.mapper;

import cc.zy.base.hr.entity.ExamineSimple;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author TK
 * @time 2022/03/09 10:09:21
 */
public interface ExamineSimpleMapper extends BaseMapper<ExamineSimple> {
    /**
     * 查找试卷详细信息
     *
     * @param page    分页对象
     * @param examineSimple 用户对象，用于传递查询条件
     * @return Ipage
     */
    <T> IPage<ExamineSimple> listExamineSimpleDetailPage(Page<T> page, @Param("examineSimple") ExamineSimple examineSimple);

    /**
     * @Author TK
     * @Description 统计考卷数量通过条件
     * @param examineSimple:标签对象
     * @return long
     */
    long countExamineSimpleDetail(@Param("examineSimple") ExamineSimple examineSimple);


    /**
     * @Author TK
     * @Description 通过id查找考卷
     * @Param [examineSimpleId]
     * @return cc.zy.base.hr.entity.ExamineSimple
     */
    ExamineSimple getById(Integer examineSimpleId);

    /**
     * 查找考卷详细信息
     * @param examineSimple 标签对象，用于传递查询条件
     * @return List<ExamineSimple>
     */
    List<ExamineSimple> listExamineSimpleDetail(@Param("examineSimple") ExamineSimple examineSimple);

    /**
     * 查询不带分页
     * @param examineSimple 标签对象，用于传递查询对象
     * @return List<ExamineSimple>
     */
    List<ExamineSimple> listExamineSimpleListNotPage(@Param("examineSimple") ExamineSimple examineSimple);



    /**
     * @param title: 考卷名称
     * @return: List<ExamineSimple>
     * @description:
     */
    List<ExamineSimple> isRepetitive(@Param("title") String title);

    /**
     * @Description 通过传入的title查询id
     * @param title
     * @return java.lang.Integer
     */
    Integer getId(@Param("title") String title);

    /**
     * @Description 通过传入条件查询id
     * @param title
     * @return java.lang.Integer
     */
    Integer selectExamineSimpleId(@Param("title") String title);
}
